package org.example;

import com.alibaba.excel.EasyExcel;
import org.example.excel.MaterialExcel;

import java.util.LinkedList;
import java.util.List;

public class MaterialExcelDataRandom {
    public static void main(String[] args) {
        List<MaterialExcel> list = new LinkedList<>();
        for (int i = 0; i < 50000; i++) {
            MaterialExcel material = new MaterialExcel();
            material.setName("物资" + i);
            material.setStock(1000);
            material.setWarningStock(200);
            list.add(material);
        }
        EasyExcel.write("C:\\5万行物资数据.xls").sheet().doWrite(list);
    }
}
